import tensorflow as tf

X1 = tf.Variable([[7, 0, -9], [0.55, -113, 12]], dtype=tf.float32);
X2 = tf.Variable([[17, 0, -9], [0.545, -23, 112]], dtype=tf.float32);

pow = tf.pow(X1, X2)

d_pow_X1 = tf.gradients(pow, X1)
d_pow_X2 = tf.gradients(pow, X2)

with tf.Session() as sess:
    sess.run(tf.global_variables_initializer())
    
    print('------pow------')
    print(sess.run(pow))
    
    print('------d_pow_X1------')
    print(sess.run(d_pow_X1))
    print('------d_pow_X2------')
    print(sess.run(d_pow_X2))